<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <script>
      function f1() {
        return 200 + 300
      }
      var s0 = 'xxx'
      var s1 = 'abc' + s0 + 'def'
      //引用了一个变量
      var s2 = `abc ${s0} def`
      console.log(s2)
      //可以写表达式
      var s3 = `abc ${100 + 300} def`
      console.log(s3)
      //可以调用函数
      var s4 = `abc ${f1()} def`
      console.log(s4)
      //可以写多行字符串，不用像c#和java那样用\n换行
      var s5 = `abc
      def 
      ghi`
      console.log(s5)

      var a = '100',
        b = '200'
      a = [b][((b = a), 0)]
      console.log(a, b)
    </script>
  </body>
</html>
